home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-01 / tcoop10a.zip / HPP.ZIP / MENU.HPP < prev    next >
C/C++ Source or Header  |  1991-11-20  |  1KB  |  50 lines

  1. //
  2. //      MENU.HPP
  3. //    version 1.00    11/15/91
  4. //    header for MENUMGR.CPP text based menu manager
  5. //    copyright (c) 1991 by James S. Clark
  6. //    all rights reserved
  7. //
  8.  
  9.  
  10. #ifndef MENU_HPP
  11. #define MENU_HPP
  12.  
  13.  
  14. #include "WINDOW.HPP"
  15.  
  16.  
  17. class     Menu {
  18. protected:
  19.     Window  *owner;                    // menu window pointer
  20.     int    id;                // menu id
  21.     int    x, y;                // upper left position
  22.     int    type;                // type bar or pop-up
  23.     int    flag;                // menu window flags
  24.     int    width;                // width of window
  25.     int     numitems;            // number of items
  26.     char    key[25];                        // menu hot keys
  27.     char    *itemlist;            // formatted item list
  28.     colors  *color;
  29. private:
  30.     void    hilightselection(int select, int last);
  31. public:
  32.     Menu    ()     {};
  33.     Menu    (char *title, int nx, int ny, int flags, char *str, colors *clr);
  34.     int    close    ();
  35.     int     select    ();
  36. };
  37.  
  38.  
  39. class     MenuBar : public Menu {
  40. public:
  41.     MenuBar    ();
  42.     MenuBar (char *title, int nx, int ny, int flags, char *str, colors *clr);
  43. };
  44.  
  45.  
  46. // int     Dialog::open(int x1, int y1, int x2, int y2, int flags, char *title, char *text);
  47. // int     Error::open (int x, int y, int flags, char *title, char *text);
  48.  
  49. #endif
  50.